package com.wonking.springbootv2.service.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.redis.core.RedisTemplate;
import org.springframework.stereotype.Service;

import com.wonking.springbootv2.service.RedisService;
@Service
public class RedisServiceImpl implements RedisService{
	
	@Autowired
	private RedisTemplate redisTemplate;

	@Override
	public Object getValue(String value) {
		return redisTemplate.opsForValue().get("key1");
	}

	@Override
	public void setValue(String key, Object value) {
		 
		redisTemplate.opsForValue().set(key,value);
	}

}
